<template>
    <van-grid :column-num="channelArr.length">
        <!-- 注意：这里还要点击跳转，即@click=this.$route.push('路径') -->
        <van-grid-item :icon="item.icon_url" :text="item.name" v-for="item in channelArr" :key="item.id" />
    </van-grid>
</template>

<script>
// 引入组件
import Vue from 'vue';
import { Grid, GridItem } from 'vant';
Vue.use(Grid);
Vue.use(GridItem);

export default {
    // 接收props: ['接收值'],或者是props: {channelArr：{ } }
    props: ['channelArr'],
    name: 'GridCom',
    data() {
        return {
        };
    },


}

</script>
<style lang='less' scoped>

</style>
